<template>
  <div>
    <div class="weekend-title">周末去哪儿</div>
    <ul>
      <li class="item border-bottom"
          v-for="item in weekendList"
          :key="item.id"
      >
        <div class="wrapper">
          <img class="item-img" :src="item.imgUrl">
        </div>
        <div class="item-info">
          <p class="item-title">{{item.title}}</p>
          <p class="item-desc">{{item.desc}}</p>
        </div>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: 'HomeRecommend',
  props: {
    weekendList: Array
  }
}
</script>

<style lang="stylus" scoped>
  @import '~styles/mixins.styl'
  .weekend-title
    height: .7rem
    line-height: .8rem
    text-indent: .2rem
    background: #eee
  .item
    overflow: hidden
    .wrapper
      overflow: hidden
      height: 0
      padding-top: .1rem
      padding-bottom: 38%
      background: #eee
    .item-img
      width: 100%
    .item-info
      padding: .2rem
      min-width: 0
      .item-title
        line-height: .4rem
        font-size: .28rem
        ellipsis()
      .item-desc
        line-height: .3rem
        margin-top: .1rem
        margin-bottom: .1rem
        font-size: .22rem
        ellipsis()
</style>
